home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CBM Funet Archive
/
cbm-funet-archive-2003.iso
/
cbm
/
demodisks
/
drives
/
1581-demo.lzh
/
partition aid
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
1994-10-19
|
4KB
|
144 lines
100 ifa=74then501
101 gosub880:ifsx=0then145
110 (NULL)15:(NULL)clr:if(NULL)(0)=5then(NULL)%
120 if(NULL)(0)<>5then(NULL)&
130 (NULL)130:close15:ifer=5then260
140 sys11252
145 poke53280,0:poke53281,0:l1$=" [155][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192]"
150 printchr$(142)"[147]"l1$
160 printspc(9)"[159]partition aid"
170 printl1$
180 printspc(5)"[155] 1. show partitions"
190 printspc(5)"[155] 2. create partition"
200 printspc(5)"[155] 3. directory"
210 printspc(5)"[155] 4. change unit
220 [153][166]5)"list 5. quit":[153]l1$
230 [139]ru[178]1[167]290
240 :u[178]8
250 [141]890:[139]dr[178]8[167]290
260 u[178]u[170]1:[139]u[179]12[167]250
270 [139]ru[178]0[167][137]930
280 :[137]240
290 ru[178]1:[153][166]4)"openunit:"u"open drive: 1581" :[153]l1$
300 [161]k$:[139]k$[178]""[167]300
310 [145][197](k$)[137]510,960,360,790,330
320 [137]300
330 [153]"load":[128]
340 [143]
360 [153]"load"l1$
370 [153][166]10)"opendirectory":[153]l1$
390 [159]15,u,15:[159]96,u,96,"$0":[141]820:[139]a[177]19[167][160]96:[160]15:[137]100
400 [153][166]5)"list"[199](34);
410 [158]6145:[158]6170:[153]
420 [129]y[178]1[164]15:[158]6145
430 [139][194](6144)[179][177]0[167]490
440 [153][166]5)[199](34);
450 [158]6170
460 [153]:[130]y
470 [141]850:[153]:[129]y[178]1[164]17:[153]"onon ":[130]y
480 [153]"onon":[137]420
490 [160]96:[160]15:[141]850:[137]145
500 [139]a[179][177]74[167]100
501 a[178]0:[153]"list there is no sub-directory. on":[141]1920
502 [139]x$[178]"y"[167][159]15,u,15:[137]1670
503 [159]15,u,15,"i0":[160]15:[137]100
510 [153]"load"l1$
520 [153][166]9)"openshow partitions"
530 [153]l1$
540 [159]15,u,15:[159]96,u,96,"$0":[141]820:[139]a[177]19[167][160]96:[160]15:[137]500
550 [153][166]3)"list "[199](34);
560 [158]6145:[158]6170:[153]" ":yy[178]0:zz[178]0
570 [129]y[178]1[164]296:[158]6145
580 [139][194](6144)[179][177]0[167]640
590 [158]6213:[139][194](6191)[178][198]("m")[167]yy[178]yy[170]1:zz[178]zz[170]1
600 [139]yy[178]8[167]yy[178]0:[137]620
610 [130]y:[137]640
620 [141]850:[153]:[129]y[178]1[164]10:[153]"onon ":[130]y
630 [153]"onon":[137]570
640 [160]96:[160]15
650 [153] "listwant to go to a partition ?"
660 [133]"ycmdcmdcmd";x$: [139] x$[179][177]"y" [167] 145
670 [153] "listok, enter a partition name."
680 p$[178]"root":[133]"rootcmdcmdcmdcmdcmdcmd";p$:
690 [139]zz[178]0[175]p$[179][177]"root"[167][153]"onon":[137]680
700 x[178][195](p$):[139]x[177]16[167][153]"onon":[137]680
710 [139]x[178]0[167]145
720 [139] ((zz[178]0) [176] (p$[178]"root"))[167] [159]15,u,15,"i0":[137]740
730 [159]15,u,15,"/0:"[170]p$
740 [141]820
750 [139]a[178]2[167][153][166]3)"waitliststatus: "b$;c;d:[141]850:[137]770
760 [139]a[178]0[167][153][166]4)"waitliststatus:oncmdcmdcmdcmd";:[141]840
770 [160]15:[137]145
780 [143]
790 [153]" ":[153]"onon":u[178]u[170]1
800 ru[178]2:[137]250
810 [143]
820 [132]15,a,b$,c,d:[139]a[179]20[167][142]
830 [153]"listdisk error:"
840 [153]""a;b$;c;d:[141]850:[142]
850 [139]a[178]74[167][142]
851 [153]:[153]"listpress any key to continue"
860 [161]k$:[139]k$[178]""[167]860
870 [142]
880 sx[178][182]([194](65533)[178]255):[142] :[143] sx=0 if c64, sx=1 if c128
890 [159]15,u,15:[141]900:[160]15:[142]
900 [152]15,"m-r"[199](198)[199](229)[199](1):[161]#15,a$:a$[178]a$[170][199](0)
910 [139][198](a$)[178]255[167]dr[178]8:[142]
920 dr[178]7:[142]
930 [153]"list1581 drive not presenton":[128]
950 [143]
960 [153]"load"l1$
970 [153][166]8)"opencreate partition"
980 [153]l1$
990 [153]"listto create a sub-directory"
1000 [153]"listyour partition must: wait"
1010 [153]" (1) start on sector 0"
1020 [153]" (2) be at least 120 blocks"
1030 [153]" (3) be a multiple of 40 blocks"
1040 [153] "list enter a partition name. "
1050 p$[178]"end":[133]"endcmdcmdcmdcmdcmd";p$:
1060 x[178][195](p$):[139]x[177]16[167][153]"onon":[137]1050
1070 [139]x[178]0[176]p$[178]"end"[167]145
1080 [153] "list first track (1-39 or 41-80)"
1090 t[178]1:[133]"1cmdcmdcmd";t:
1100 [139](t[179]1)[176](t[178]40)[176](t[177]80)[167][153]"onon":[137]1090
1110 [153] "list first sector (0-39) "
1120 s[178]0:[133]"0cmdcmdcmd";s:
1130 [139](s[179]0)[176](s[177]39)[167][153]"onon":[137]1120
1140 [153] "list number of blocks in partition"
1141 n[178]120:[133]"120cmdcmdcmdcmdcmd";n:
1150 [139] n[178]0 [167] [153] "onon": [137]1141
1170 [139][181](n[173]40)[178]n[173]40[167]1210
1180 [153]"listnot a multiple of 40."
1190 c$[178]"n":[133] "continue anyway (y/n): ? ncmdcmdcmd";c$
1191 [139]c$[178]"n"[167][153]"onononon":[137]1141
1200 [139]c$[179][177]"y"[167][153]"onon":[137]1190
1210 a1[178][181](n[173]256) : a2[178]n[171]a1[172]256
1220 cm$[178]"/0:"[170]p$[170]","[170][199](t)[170][199](s)[170][199](a2)[170][199](a1)[170]",c"
1230 [153]"":[129]x[178]1[164]20:[153]" ":[130]x
1240 [153]"listcreating partition: ";
1242 [139][195](p$)[179]8[167][153]p$:[153]:[137]1250
1243 [153]:[153]""p$:[153]:[137]1250
1250 [159]15,u,15:[152]15,cm$:[141]820
1255 [139]a[177]19[167][160]15:[137]145
1260 [153]"liststatus: "a;b$;c;d:[137]1310
1300 [160]15:[141]850:[137]145
1310 [139][181](n[173]40)[179][177]n[173]40[167]1300
1320 [139]n[179]120[167]1300
1330 [139]s[179][177]0[167]1300
1650 [141]1920
1660 [139] x$[179][177]"y" [167][160]15:[137]145
1670 [153] "listok, enter a directory name."
1675 [153]""p$;:x[178][195](p$)[170]2:[129]xx[178]1[164]x:[153]"cmd";:[130]xx
1680 [133]h$:
1700 x[178][195](h$):[139]x[177]16[167][153]"onon":[137]1680
1710 [139]x[178]0[167][160]15:[137]145
1800 [153] "listok, enter 2 character id. "
1880 id$[178]"xx":[133]"xxcmdcmdcmdcmd";id$:
1890 [139][195](id$)[177]2[176][195](id$)[179]2[167][153]"onon":[137]1880
1899 [152]15,"/0:"[170]p$
1900 [152]15,"n0:"[170]h$[170]","[170]id$
1910 s[178]1:[153]:[141]820:[137]1255
1920 [153] "listwant to make a sub-directory"
1921 [153] "for this partition? ":[133]"ycmdcmdcmd";x$:[142]